package com.medical.interrogation.controller;

import com.medical.common.core.domain.Result;
import com.medical.interrogation.domain.ReceivePatients;
import com.medical.interrogation.service.ReceivePatientsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;

@RestController
@RequestMapping("/receivePatients")
public class ReceivePatientsController {


    @Autowired
    private ReceivePatientsService receivePatientsService;


    /**
     * 接诊台新增
     * @param receivePatients
     * @return
     */
    @PostMapping("/receiveInsert")
    public Result receiveInsert(@RequestBody ReceivePatients receivePatients){
        return Result.success(receivePatientsService.receiveInsert(receivePatients));
    }

    @GetMapping("/receiveUpdate")
    public Result receiveUpdate(@RequestParam Integer id){
        return Result.success(receivePatientsService.receiveUpdate(id));
    }

    @GetMapping("/receiveUpd")
    public Result receiveUpd(@RequestParam Integer id){
        return Result.success(receivePatientsService.receiveUpd(id));
    }

    @GetMapping("/receiveServiceId")
    public Result receiveServiceId(@RequestParam Integer id){
        return Result.success(receivePatientsService.receiveServiceId(id));
    }

}
